package Users;

import book.BookList;
import operation.IOPreparation;

/**
 * @ClassDescription:
 * @JdkVersion: 1.8
 * @Author: 李白
 * @Created: 2024/8/19 16:36
 */
public abstract class Users {
    protected String name;
    protected IOPreparation[] ioPreparations;
    public abstract void work();
    public Users(String name){
        this.name = name;
    }
    public abstract int menu();
    public void doIopreparation(int choice, BookList bookList){//括号里的参数只是说要用到这两个参数，如何得到和使用是我们的事
        ioPreparations[choice].work(bookList);//数组里的每一个元素都是一个类，这些类都在实现一个功能，用work方法实现
    };
}
